from flask import Flask

app = Flask(__name__)

@app.route('/article/<id>')
def index(id):
    print(f'接收到的文章{id}')
    print(type(id))
    return f'返回了文章id:{id}'

@app.route('/int/<int:id1>')
def index_int(id1):
    print(f'接收到的文章{id1}')
    print(type(id1))
    return f'返回了文章id:{id1}'

@app.route('/float/<float:id>')
def index_float(id):
    print(f'接收到的文章{id}')
    print(type(id))
    return f'返回了文章id:{id}'

@app.route('/path/<path:id>')
def index_path(id):
    print(f'接收到的文章{id}')
    print(type(id))
    return f'返回了文章id:{id}'

@app.route('/uuid/<uuid:id>')
def index_uuid(id):
    print(f'接收到的文章{id}')
    print(type(id))
    return f'返回了文章id:{id}'

@app.route('/<any(user,item):tmp>/<int:id>')
def index_any(tmp,id):
    print(f'接收到的文章{id}{tmp}')
    print(type(id))
    return f'返回了文章id:{id}'

from werkzeug.routing import BaseConverter

if __name__ == '__main__':
    app.run(debug=True)